let computed = {
  toBeApprovedId() {
    let list = this.$store.state.dict.materialRequestStatus.labels || []
    return list.find((item) => item.value === 'ToBeApproved').id || ''
  },
  supplyId() {
    let list = this.$store.state.dict.materialRequestType.labels || []
    return list.find((item) => item.value === 'Supply').id || ''
  },
  materialRequestStatus() {
    return this.$store.state.dict.materialRequestStatus.labels || []
  },
  // 搜索配置参数
  searchList() {
    let list = [
      {prop: 'turnoverNumbers', label: '周转码', colConfig: {minWidth: 240, align: 'left'}},
      {prop: 'number', label: '要料申请编号', colConfig: {minWidth: 160}},
      {
        prop: 'materialRequestStatusLabel',
        label: '要料状态',
        noSearch: true,
        colConfig: {width: 110, comp: 'materialState', sortable: false}
      },
      {prop: 'requestDate', label: '要料申请时间', searchConfig: {type: 'date'}, colConfig: {minWidth: 160}},
      {
        prop: 'requireServiceDate',
        label: '要求送达时间',
        searchConfig: {type: 'date'},
        colConfig: {minWidth: 110, formatToDay: true}
      },
      {prop: 'workstageName', label: '要料工序', noSearch: true, colConfig: {minWidth: 100, sortable: false, align: 'left'}},
      {prop: 'requester', label: '要料人', colConfig: {minWidth: 100}},
      {
        prop: 'materialRequestTypeLabel',
        label: '要料类型',
        noSearch: true,
        colConfig: {minWidth: 90, sortable: false}
      },
    ]
    return list
  },
  // 列循环
  columnList() {
    return this.searchList.filter(item => item.noForCol !== true)
  },
}
export default computed
